FROM openjdk:8-jre-alpine
LABEL maintainer="tcy"
COPY target/*.jar /app.jar

RUN apk add -U tzdata; \
ln -sf /user/share/zoneinfo/Asia/Shanghai /etc/localtime; \
echo 'Asia/Shanghai' >/etc/timezone; \
touch /app.jar;

ENV JAVA_OPTS=""
ENV PARAMS=""


EXPOSE 8080


CMD ["sh", "-c", "java $JAVA_OPTS -jar /app.jar $PARAMS"]
